﻿<Application 
    x:Class="ScopaSL.App"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"       
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone">

    <!--Application Resources-->
    <Application.Resources>
        
        
        <ControlTemplate x:Key="ButtonTemplate" TargetType="Button">
            <Grid>
                <VisualStateManager.VisualStateGroups>
                    <VisualStateGroup x:Name="CommonStates">
                        <VisualState x:Name="MouseOver"/>
                        <VisualState x:Name="Normal"/>
                        <VisualState x:Name="Pressed">
                            <Storyboard >
                                <DoubleAnimationUsingKeyFrames RepeatBehavior="1" AutoReverse="True" Storyboard.TargetProperty="(UIElement.RenderTransform).(TranslateTransform.Y)" Storyboard.TargetName="normal" BeginTime="00:00:00">
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.0000000" Value="0"/>
                                    <SplineDoubleKeyFrame KeyTime="00:00:00.6000000" Value="16"/>
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </VisualState>
                    </VisualStateGroup>
                </VisualStateManager.VisualStateGroups>
                <Image x:Name="normal" Height="250" Width="190" Opacity="1" Stretch="Uniform" Source="/ScopaSL;component/Content/Images/Menu/button2.png">
                    <Image.RenderTransform>
                        <TranslateTransform ></TranslateTransform>
                    </Image.RenderTransform>
                </Image>
                <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
            </Grid>
        </ControlTemplate>

        
    </Application.Resources>

    <Application.ApplicationLifetimeObjects>
        <!--Required object that handles lifetime events for the application-->
        <shell:PhoneApplicationService 
            Launching="Application_Launching" Closing="Application_Closing" 
            Activated="Application_Activated" Deactivated="Application_Deactivated"/>
    </Application.ApplicationLifetimeObjects>

</Application>